home *** CD-ROM | disk | FTP | other *** search
- /* Constants for Rotate a Bitmap program */
-
- #define scale 1 /* use 2 for 1024 pixel wide screen */
-
- #define kScreenHeight scale*342
- #define kScreenWidth scale*512
- #define kWindowBase (18+20) /* Menubar & Window Header */
- #define kWindowHeight (kScreenHeight - kWindowBase)
- #define kWindowWidth (kScreenWidth)
-
- /* Resource ID constants for Rotate a Bitmap program */
-
- #define rBell 1024 /* Resource ID of Bell Pict */
-
- #define rWindow 128 /* Resource ID of the Window */
-
- #define rMenuBar 128 /* Resource ID of Menubar */
-
- #define mApple 128 /* Resource IDs of Menus */
- #define aboutMeCommand 1
-
- #define mFile 129
- #define quitCommand 1
-
- #define mImage 130
- #define GarbageCommand 1
- #define BlackCommand 2
- #define WhiteCommand 3
- #define BellCommand 5
- #define StretchCommand 6
-
- #define mRotate 131
- #define RotAllCommand 1
- #define Rot0Command 3 /* the 8 rotations start with this one */
-
- #define rTextStr 128 /* Alert text strings */
- #define kAboutText 1 /* About box text */
- #define kNoBell 2 /* Can't find the Bell */
-
- #define rMsg 128 /* For the About Rotate... message */
- #define rAlert 129 /* general error alert */
-
- /* Apple Human Interface Note# 10 for Dialog and Alert Box layout. */
-
- #define kIconSize 32 /* Standard icon size */
-
- #define kSpaceStd 13 /* White space between most elements */
- #define kSpaceIcon 23 /* White space to left & right of icon */
- #define kInsetStd (kSpaceStd-3) /* Standard white space inset */
- #define kInsetIcon (kSpaceIcon-3) /* White space inset of icon */
-
- #define kLineHeight 16 /* height of a single line of Chicago-12 */
- #define kButtonHeight 20 /* standard button height */
- #define kCancelLen 41 /* width of 'Cancel' in Chicago-12 */
- #define kButtonWidth (kCancelLen+18) /* standard button width */
- #define kContinueLen 62 /* width of 'Continue' in Chicago-12 */
- #define kContinueWidth (kContinueLen+18) /* 'Continue' button width */
-
- /* Alert Box definition */
-
- #define kAlertWidth 300 /* Width of the Alert */
- #define kAlertTextLines 3 /* Number of text lines in Alert */
- #define kAlertTop 60
- #define KAlertLeft ((512 - kAlertWidth)/2)
-
- #define kAlertIconLeft kInsetIcon
- #define kAlertIconRight (kAlertIconLeft+kIconSize)
- #define kAlertIconTop kInsetStd
- #define kAlertIconBottom (kAlertIconTop+kIconSize)
-
- #define kAlertTextLeft (kAlertIconRight + kSpaceIcon - 1)
- #define kAlertTextRight (kAlertWidth - kInsetStd)
- #define kAlertTextTop kInsetStd
- #define kAlertTextBottom (kAlertTextTop + (kAlertTextLines * kLineHeight))
-
- #define kAlertButtonTop (kAlertTextBottom + kSpaceStd)
- #define kAlertButtonBottom (kAlertButtonTop + kButtonHeight)
-
- #define kAlertOkRight (kAlertWidth - kInsetStd)
- #define kAlertOkLeft (kAlertOkRight - kButtonWidth)
-
- #define kAlertHeight (kAlertButtonBottom + kInsetStd)
-
- /* Message Box definition */
-
- #define kMsgWidth 300 /* Width of the Message dialog */
- #define kMsgTextLines 7 /* Number of text lines in Message */
-
- #define kMsgTextLeft (2*kInsetStd)
- #define kMsgTextRight (kMsgWidth - kMsgTextLeft)
- #define kMsgTextTop kInsetStd
- #define kMsgTextBottom (kMsgTextTop + (kMsgTextLines * kLineHeight))
-
- #define kMsgButtonTop (kMsgTextBottom + kSpaceStd)
- #define kMsgButtonBottom (kMsgButtonTop + kButtonHeight)
-
- #define kMsgOkRight (kMsgWidth - kInsetStd)
- #define kMsgOkLeft (kMsgOkRight - kContinueWidth)
-
- #define kMsgHeight (kMsgButtonBottom + kInsetStd)
-
-